import request from '../../utils/request'

//获取权限列表
export const getRights = function getRights(data:any) {
    return request({
      url: '/api/Right/GetRights',
      method: 'get',
      params:data
    })
  }

  //获取单个权限
  export const getSingleRight = function getSingleRight(data:any) {
    return request({
      url: '/api/Right/GetSingleRight',
      method: 'get',
      params:data
    })
  }

  //新增权限
  export const addRight = function addRight(data:any) {
    return request({
      url: '/api/Right/AddRight',
      method: 'post',
      data:data
    })
  }

  //删除权限
  export const deleteRights = function deleteRights(data:any) {
    return request({
      url: '/api/Right/DeleteRights',
      method: 'post',
      data:data
    })
  }

  //禁用-取消禁用 权限
  export const BanRights = function BanRights(data:any) {
    return request({
      url: '/api/Right/BanRights',
      method: 'post',
      data:data
    })
  }

  //发布-取消发布 权限
  export const PublishRights = function PublishRights(data:any) {
    return request({
      url: '/api/Right/PublishRights',
      method: 'post',
      data:data
    })
  }